import { PanServer } from './panServer';
import publishObjectPath from '@/util/configRegistry';

const newUrl = publishObjectPath.value.newserverUrl
// 综合态势服务
export class CompreSituationServer extends PanServer {

    constructor(opt: any, axiosFilterFn?: any) {
        super(opt, axiosFilterFn);
    }


    public getMigrateMap(areaId: any, date: any, migrateType: any) {
        const url = newUrl + '/beijing/ncov/pub/sens/getMigrateMap' +
            '?area_id=' + areaId + "&date=" + date + "&migrate_type=" + migrateType;
        return this.rSerivce.serverObj.get(url);
    }

    // 获取全国迁徙图数据
    public findMigratePeople(areaId: any, date: any, migrateType: any) {
        const url = newUrl + "/beijing/ncov/pub/sens/findMigratePeople" +
            '?area_id=' + areaId + "&date=" + date + "&migrate_type=" + migrateType;
        return this.rSerivce.serverObj.get(url);
    }


    // public getClusterPoint(districtCode: any, type: any, bound: any) {
    //     const url = '/group/defense/list' +
    //         '?districtCode=' + districtCode + "&type=" + type;// + "&bound=" + bound
    //     return this.rSerivce.serverObj.get(url);
    // }

    public getClusterPoint(districtCode: any, type: any, bound: any) {
        const url = '/group/defense/countsandlist' +
            '?districtCode=' + districtCode + "&type=" + type;// + "&bound=" + bound
        return this.rSerivce.serverObj.get(url);
    }

}
